package cn.shop.merchant.service;

import cn.hutool.core.util.StrUtil;
import cn.shop.merchant.service.impl.BaseService;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.Objects;
import java.util.function.Predicate;

/**
 * @author : 李一涵
 * @date : Created in 2021-11-4 13:48
 * @description :
 */
public class BaseServiceImpl<C extends BaseMapper<T>, T> extends ServiceImpl<C, T> implements BaseService<T> {

    public static Predicate<Object> notNull = Objects::nonNull;
    public static Predicate<String> notBlank = StrUtil::isNotBlank;
    public static Predicate<Integer> notZero = i -> i != 0;
    public static Predicate<Integer> isAsc = i -> i > 0;

}
